package com.augrain.microframework.lock.model;

import lombok.Getter;
import lombok.Setter;

/**
 * 锁信息
 *
 * @author biaoy
 * @since 2021/06/10
 */
@Getter
@Setter
public class LockInfo {
    /**
     * 锁类型
     */
    private LockType type;

    /**
     * 锁名称
     */
    private String name;

    /**
     * 获取锁等待时长
     */
    private long waitTime;

    /**
     * 锁持有时长
     */
    private long leaseTime;

    public LockInfo() {
    }

    public LockInfo(LockType type, String name, long waitTime, long leaseTime) {
        this.type = type;
        this.name = name;
        this.waitTime = waitTime;
        this.leaseTime = leaseTime;
    }
}
